﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="UserManagerRelation.aspx.cs" Inherits="GovernmentOfficeProject.LevelViewUI.admin.UserManagerRelation" MaintainScrollPositionOnPostback="true"  %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title></title>

    <style type="text/css">
        .style1
        {
            width: 223px;
        }
        .style2
        {
            width: 223px;
        }
        .style3
        {
            width: 223px;
            height: 56px;
        }
        .style4
        {
            height: 56px;
        }
        .style5
        {
            width: 223px;
            font-weight: bold;
        }
        #form1
        {
            height: 615px;
        }
    </style>   
    <script type="text/javascript" >
        function setGv1ScollTop() {
            var stp = document.getElementById("divUserGV1").scrollTop;
            document.getElementById("<%=hiddDivGv1ScollTop.ClientID%>").value = stp;
        }
    </script>
</head>
<body>
    <form id="form1" runat="server">     
    <asp:ScriptManager ID="ScriptManager1" runat="server">
            </asp:ScriptManager>
    <div style="height: 445px; width: 989px">        
        <table style="width:100%;">
            <tr>
                <td class="style5" style="border-style: groove;">
                    <div style="font-size: medium; text-align: center">
                        用 户(谁)</div>
                </td>
                <td class="style5" style="border-style: groove;">
                    <div style="font-size: medium; text-align: center">
                        用 户(具有)</div>
                </td>
                <td style="border-style: groove;">
                    <div style="font-size: medium; text-align: center">
                        <b>关系授权操作</b></div>
                </td>
            </tr>
            <tr>
                <td class="style3" style="border-style: dotted">
                    <div style="width: 224px">
                        <asp:Label ID="Label1" runat="server" Font-Size="Small" Height="18px" 
                            Text="用户名:"></asp:Label>
                        &nbsp;
                        <asp:TextBox ID="txtMasterUserName" runat="server" Font-Size="Small" Height="16px" 
                            Width="137px" BorderStyle="Inset"></asp:TextBox>
                        &nbsp;<div style="text-align: left; font-size: small; width: 198px;">
&nbsp;<asp:Label ID="Label2" runat="server" Font-Size="Small" Height="18px" Width="38px"></asp:Label>
                        &nbsp;&nbsp;
                        <asp:Button ID="btnSelectMasterUser" runat="server" Height="21px" Text="查  找" 
                                Width="60px" onclick="btnSelectMasterUser_Click" />
                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        <asp:Button ID="btnAllMasterUser" runat="server" Height="21px" Text="全  部" 
                                Width="60px" onclick="btnAllMasterUser_Click" />
                        </div>
                    </div>
                </td>
                <td class="style3" style="border-style: dotted;">
                    <div style="width: 224px">
                        <asp:Label ID="Label9" runat="server" Font-Size="Small" Height="18px" 
                            Text="用户名:"></asp:Label>
                        &nbsp;
                        <asp:TextBox ID="txtControlledUserName" runat="server" Font-Size="Small" Height="16px" 
                            Width="137px" BorderStyle="Inset"></asp:TextBox>
                        <div style="text-align: left; font-size: small; width: 198px;">
&nbsp;<asp:Label ID="Label10" runat="server" Font-Size="Small" Height="18px" Width="38px"></asp:Label>
                        &nbsp;&nbsp;
                        <asp:Button ID="btnSelectControlled" runat="server" Height="21px" Text="查  找" 
                                Width="60px" onclick="btnSelectControlled_Click" />
                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        <asp:Button ID="btnAllControlledUser" runat="server" Height="21px" Text="全  部" 
                                Width="60px" onclick="btnAllControlledUser_Click" Enabled="False" />
                        </div>
                    </div>
                </td>
                <td style="border-style: dotted; font-size: 3px;" class="style4">
<asp:UpdatePanel ID="UPOPeration" runat="Server">
<ContentTemplate>
                        <asp:Label ID="lblOperationShow" runat="server" Font-Size="Small" Height="16px" 
                            Width="500px" ForeColor="#3399FF" style="font-weight: 700">操作状态:</asp:Label>

                    <div style="height: 15px; font-size: small; vertical-align: middle;">
                        <asp:Label ID="Label5" runat="server" ForeColor="#009933" 
                            style="font-weight: 700" Text="用户"></asp:Label>
                        <asp:TextBox ID="txtRelationMasterUserName" runat="server" BorderStyle="Outset" Height="21px" 
                            ReadOnly="True" Width="85px">LoginNameABC</asp:TextBox>
                        <asp:Label ID="Label6" runat="server" ForeColor="#009933" 
                            style="font-weight: 700" Text="具有用户"></asp:Label>
                        <asp:TextBox ID="txtRelationControlledUserName" runat="server" 
                            BorderStyle="Outset" Height="21px" 
                            ReadOnly="True" Width="85px">LNmd321b</asp:TextBox>
                        <asp:Label ID="Label7" runat="server" ForeColor="#009933" 
                            style="font-weight: 700" Text="的"></asp:Label>
                        <asp:TextBox ID="txtRelationPrivilege" runat="server" BorderStyle="Outset" 
                            Font-Size="Small" Height="21px" ReadOnly="True" Width="151px">日程管理-个人日程-查看</asp:TextBox>
                        <asp:Label ID="Label8" runat="server" ForeColor="#009933" 
                            style="font-weight: 700" Text="权限."></asp:Label>
</ContentTemplate>
</asp:UpdatePanel>   
&nbsp;</div>
                </td>
            </tr>            
            <tr>

                <td class="style1" style="border-style: groove">                    
                    <div id="divUserGV1" style="width: 218px; overflow: auto; height: 309px;" onclick="javascript:setGv1ScollTop();">
<asp:UpdatePanel ID="upGVMU" runat="Server">
<ContentTemplate>
                            <asp:GridView ID="GridViewMasterUser" runat="server" AutoGenerateColumns="False" 
                            CellPadding="1" CellSpacing="1" DataKeyNames="UserID,LoginName" 
                            ForeColor="#333333" GridLines="Vertical" 
                            Width="200px" Height="100%" onrowcreated="GridViewMasterUser_RowCreated" 
                            onselectedindexchanged="GridViewMasterUser_SelectedIndexChanged" >
                            <RowStyle BackColor="#E3EAEB" />
                            <Columns>
                                <asp:BoundField DataField="UserID" HeaderText="UserID" SortExpression="UserID" 
                                    Visible="False" />
                                <asp:BoundField DataField="LoginName" HeaderText="登录名" 
                                    SortExpression="LoginName">
                                <HeaderStyle Width="99px" Font-Size="Small" HorizontalAlign="Center" />
                                <ItemStyle Width="99px" />
                                </asp:BoundField>
                                <asp:BoundField DataField="Backup1" HeaderText="备注" 
                                    SortExpression="Backup1" Visible="False">
                                <HeaderStyle Width="150px" />
                                </asp:BoundField>
                                <asp:CommandField SelectText="" ShowSelectButton="True">
                                <HeaderStyle Width="1%" />
                                <ItemStyle Width="1%" />
                                </asp:CommandField>
                            </Columns>
                            <FooterStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
                            <PagerStyle BackColor="#666666" ForeColor="White" HorizontalAlign="Center" />
                            <SelectedRowStyle BackColor="#C5BBAF" Font-Bold="True" ForeColor="#333333" />
                            <HeaderStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
                            <EditRowStyle BackColor="#7C6F57" />
                            <AlternatingRowStyle BackColor="White" />
                        </asp:GridView>
</ContentTemplate>
</asp:UpdatePanel>                        
                    </div>
                </td>
                <td class="style2" style="border-style: groove">
                    <div style="width: 218px; overflow: auto; height: 309px;">
<asp:UpdatePanel ID="upGVCU" runat="Server">
<ContentTemplate>
                        <asp:DropDownList ID="ddlControlledUserListSelect" runat="server" Font-Size="Small" 
                            Height="18px" Width="198px" AutoPostBack="True" 
                            onselectedindexchanged="ddlControlledUserListSelect_SelectedIndexChanged">
                            <asp:ListItem Value="ALL">显示所有用户列表</asp:ListItem>
                            <asp:ListItem Value="REL" Selected="True">显示已关联用户列表</asp:ListItem>
                        </asp:DropDownList>
                        <asp:GridView ID="GridViewControlledUser" runat="server" AutoGenerateColumns="False" 
                            CellPadding="1" CellSpacing="1" DataKeyNames="UserID,LoginName" 
                            ForeColor="#333333" GridLines="Vertical" 
                            Width="200px" Height="100%" 
                            onrowcreated="GridViewControlledUser_RowCreated" 
                            onselectedindexchanged="GridViewControlledUser_SelectedIndexChanged">
                            <RowStyle BackColor="#E3EAEB" />
                            <Columns>
                                <asp:BoundField DataField="UserID" HeaderText="UserID" SortExpression="UserID" 
                                    Visible="False" />
                                <asp:BoundField DataField="LoginName" HeaderText="登录名" 
                                    SortExpression="LoginName">
                                <HeaderStyle Width="99px" Font-Size="Small" HorizontalAlign="Center" />
                                <ItemStyle Width="99px" />
                                </asp:BoundField>
                                <asp:BoundField DataField="Backup1" HeaderText="备注" 
                                    SortExpression="Backup1" Visible="False">
                                <HeaderStyle Width="150px" />
                                </asp:BoundField>
                                <asp:CommandField SelectText="" ShowSelectButton="True">
                                <HeaderStyle Width="1%" />
                                <ItemStyle Width="1%" />
                                </asp:CommandField>
                            </Columns>
                            <FooterStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
                            <PagerStyle BackColor="#666666" ForeColor="White" HorizontalAlign="Center" />
                            <SelectedRowStyle BackColor="#C5BBAF" Font-Bold="True" ForeColor="#333333" />
                            <HeaderStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
                            <EditRowStyle BackColor="#7C6F57" />
                            <AlternatingRowStyle BackColor="White" />
                        </asp:GridView>
</ContentTemplate>
</asp:UpdatePanel>     
                    </div>
                </td>
                <td style="border-style: groove">
                        <div style="width: 501px; font-size: small; vertical-align: super; height: 302px; overflow: auto;">
<asp:UpdatePanel ID="upGVAC" runat="Server">
<ContentTemplate>
                            <asp:GridView ID="GridViewAccess" runat="server" Height="100%" Width="100%" 
                                BackColor="White" BorderColor="#999999" BorderStyle="None" BorderWidth="1px" 
                                CellPadding="1" GridLines="None" 
                                onrowdatabound="GridViewAccess_RowDataBound"                                
                                DataKeyNames="orderID" 
                                AutoGenerateColumns="False" CellSpacing="1">
                                <RowStyle BackColor="#EEEEEE" ForeColor="Black" />
                                <Columns>
                                    <asp:TemplateField HeaderText="授 权">
                                        <ItemTemplate>
                                            <asp:CheckBox ID="CheckBoxSelect" runat="server" 
                                                Checked='<%# Bind("selectValue") %>' AutoPostBack="True" 
                                                oncheckedchanged="CheckBoxSelect_CheckedChanged" />
                                        </ItemTemplate>
                                        <HeaderStyle Width="50px" />
                                        <ItemStyle HorizontalAlign="Center" />
                                    </asp:TemplateField>
                                    <asp:BoundField DataField="menuName" HeaderText="模 块" >
                                    <ItemStyle HorizontalAlign="Center" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="buttonName" HeaderText="功 能" >
                                    <ItemStyle HorizontalAlign="Center" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="buttonID" HeaderText="按钮编号" >
                                    <ItemStyle HorizontalAlign="Center" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="menuID" HeaderText="模块编号" >
                                    <ItemStyle HorizontalAlign="Center" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="menuNo" HeaderText="模块码" >
                                    <ItemStyle HorizontalAlign="Center" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="menuParentNo" HeaderText="上级码" >
                                    <ItemStyle HorizontalAlign="Center" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="orderID" HeaderText="序号" SortExpression="orderID" >
                                    <ItemStyle HorizontalAlign="Center" />
                                    </asp:BoundField>
                                </Columns>
                                <FooterStyle BackColor="#CCCCCC" ForeColor="Black" />
                                <PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" />
                                <SelectedRowStyle BackColor="#008A8C" Font-Bold="True" ForeColor="White" />
                                <HeaderStyle BackColor="#000084" Font-Bold="True" ForeColor="White" />
                                <AlternatingRowStyle BackColor="#DCDCDC" />
                            </asp:GridView>
</ContentTemplate>
</asp:UpdatePanel> 
                        </div>
                    </td>
                    
            </tr>
            
            <tr>
                <td>
                </td>
                <td>
                </td>
                <td>
                </td>
            </tr>
            
            <tr style="height:5px;">
                <td>
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
        </table>
    
    </div>
        <asp:HiddenField ID="hiddDivGv1ScollTop" runat="server" />
    </form>
</body>
</html>
